#ifndef DRAWWAVEPAPER_H
#define DRAWWAVEPAPER_H

#if APP_DRAWWAVE

#include <QWidget>
#include <QList>
#include <QPainter>

#define DEFAULT_XD 3

class DrawWavePaper : public QWidget
{
    Q_OBJECT
public:
    explicit DrawWavePaper(QWidget *parent = 0);
    ~DrawWavePaper();

    typedef enum{
        ZOOM_1X=1,
        ZOOM_2X,
        ZOOM_3X,
        ZOOM_4X,
        ZOOM_BEST,
    }MAGNIFICATION;

public slots:
    void Draw(float d);
    void Clear();
    void setMagnification(MAGNIFICATION d);
    void setRange(float min,float max);

private:
    QList<float> datalist;

    float Range_Min,Range_Max;

    int X_d,Y_d;
    MAGNIFICATION Magnification;

    QPen pen;

protected:
    void paintEvent(QPaintEvent *e);
};

#endif

#endif // DRAWWAVEPAPER_H
